<?php
   $categories = $this->requestAction('home/product_category');   
?>

<ul id="nav">
	<?php foreach ($categories as $cat) { ?>
	<li>
		<a id="<?php echo $cat['Category']['id']?>" href="<?php echo $html->url('/home/product_category/'.$cat['Category']['id'])?>">
			<span style="margin-left:10px">
				<?php echo $cat['Category']['name']?>
			</span>
		</a>
		<ul>
			<?php foreach ($cat['Childcat'] as $cc){ ?>
				<li>
					<a id="<?php echo $cc['id']?>" href="<?php echo $html->url('/home/product_category/'.$cc['id'])?>">
						<?php echo $cc['name']?>
					</a>
				</li>
			<?php }?>
		</ul>
	</li>
<?php
	}
?>
</ul>